package org.zero.concurrency.demo.example.mq;

import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @program: concurrency-demo
 * @description: 接收消息
 * @author: 01
 * @create: 2018-10-22 20:16
 **/
@Slf4j
@Component
public class RabbitMqServer {

    @RabbitListener(queues = QueueConstants.TEST)
    private void receive(String message) {
        log.info("{}", message);
    }
}
